POV-Ray : Newsgroups : povray.newusers : #declare inside a loop - name depending on counter? : #declare inside a loop - name depending on counter? Server Time
28 Jul 2024 16:29:19 EDT (-0400)
  #declare inside a loop - name depending on counter?  
From: Tungsten
Date: 9 Jun 2008 05:10:00
Message: <web.484cf2d470f619f3f495ce020@news.povray.org>
How can I declare a variable inside a loop while the name which I declare
depends on a counter?

I'd like to generate 100 clock variables (clockX1 to clockX100). To do this, I
hoped to use something like
#declare concat("clockX",str(SomeCounter))=...
How can I tell POVRay to use the actual value of a variable/function instead of
the variable name?
In other words not to assign
 #declare Mystring=...
but to declare a new variable named by the value of Mystring.
I guess it's a simple thing (like using the $variable in IGOR) but I couldn't
find it in the help/support.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.